<!--
 * File: card.vue
 * Project: jjwww-web
 * File Created: Sunday, 2nd November 2025 7:38:15 pm
 * Description: 
 * -----
 * Last Modified: Sunday, 2nd November 2025 9:08:51 pm
 * -----
 * Copyright © 2023 - 2025 Newland Limited. All rights reserved.
 -->

<template>
  <el-card :body-style="{ padding: '0' }"class="card-box" >
    <div @click="goDetail" class="card-body">
      <img
        src="https://shadow.elemecdn.com/app/element/hamburger.9cf7b091-55e9-11e9-a976-7f4d0b07eef6.png"
        style="height: 200px; width: 100%"
        class="image"
      />
      <div style="padding: 14px">
        <span>好吃的汉堡123</span>
        <div class="bottom clearfix">
          <time class="time">{{ currentDate }}</time>
          <el-button type="text" class="button">操作按钮</el-button>
        </div>
      </div>
    </div>
  </el-card>
</template>
<script>
export default {
  data() {
    return {
      currentDate: new Date(),
    };
  },
  props: {
    // dataList
  },
  methods: {
    goDetail() {
      this.$router.push("/detail");
    },
  },
};
</script>
<style scoped>

.card-body {
    max-width: 250px;
}

.card-box {
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}
.time {
  font-size: 13px;
  color: #999;
}

.bottom {
  margin-top: 13px;
  line-height: 12px;
}

.button {
  padding: 0;
  float: right;
}

.image {
  width: 100%;
  margin: 0 auto;
}

.clearfix:before,
.clearfix:after {
  display: table;
  content: "";
}

.clearfix:after {
  clear: both;
}
</style>
